<template>
	<!-- 提示信息弹窗 -->
	<uni-popup ref="popup" type="message">
		<uni-popup-message :type="type" :message="message" :duration="duration"></uni-popup-message>
	</uni-popup>
</template>

<script>
	export default {
		props: {
			type: {
				type: String,
				default: 'info' // 'success', 'error', 'info','message'
			},
			message: String,
			duration: {
				type: Number,
				default: 3000
			}
		},
		data() {
			return {

			}
		},
		methods: {
			open() {
				this.$refs.popup.open();
			},
			close() {
				this.$refs.popup.close();
			},
		}
	}
</script>

<style>

</style>